#include "login.h"
int pop(stack *s)
{
    char c;
    if (s->len == 0)
        return -1;
    s->len--;
    c = s->p[s->len];
    return c;
}

int push(stack *s, char c)
{
    if (s->len >= MAX_LENGTH)
        return -1;
    s->p[s->len] = c;
    s->len++;
    return 0;
}